﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Themes/Shared/Seller.master" Inherits="System.Web.Mvc.ViewPage<PagedList<ShopGift>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CssContent" runat="server">
    <link type="text/css" rel="Stylesheet" href="/Style/Store.css" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="JsContent" runat="server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="MainContent" runat="server">
    <div class="tdlist">
        <table border="0" cellpadding="0" cellspacing="0" width="100%">
            <tr>
                <th>
                    编号
                </th>
                <th>
                    名称
                </th>
                <th>
                    商户名
                </th>
                <th>
                    状态
                </th>
                <th>
                    是否上架
                </th>
            </tr>
            <%if (null != Model)
              {
                  foreach (ShopGift data in Model)
                  {
            %>
            <tr>
                <td>
                    <%=data.ID%>
                </td>
                <td>
                    <%=data.GiftName %>
                </td>
                <td>
                    <%=data.GetShop().FullName.WriterString("&nbsp;")%>
                </td>
                <td>
                    <%switch (data.DataState)
                      {
                          case 0:
                              Writer.Write("正常");
                              break;
                          case 1:
                              Writer.Write("已删除");
                              break;
                          default:
                              Writer.Write("&nbsp;");
                              break;
                      }%>
                </td>
                <td>
                    <%if(data.IsOnsale){
                      Writer.Write("上架");
                  }
                      else{
                      Writer.Write("已下架");
                  }  %>
                </td>
            </tr>
            <%}
              } %>
        </table>
    </div>
    <div class="pager" style="clear: both; padding-top: 10px">
        <%= Html.Pager("GiftList","Seller",Model.PageIndex, Model.PageSize, Model.TotalCount)%>
    </div>
</asp:Content>
